package com.deyuanyun.pic.ctrl.controller.dto;

import java.math.BigDecimal;

import com.deyuanyun.pic.ctrl.domain.ExinspOclpoint;
import com.deyuanyun.pic.ctrl.enumeration.CurrentFerenceEnum;
import com.deyuanyun.pic.ctrl.enumeration.RepairStateEnum;
import com.deyuanyun.pic.settings.support.biz.CodeUtil;

/**
 *  漏损点信息列表展示dto
 *  因为不涉及导出Excel，所以我就直接继承ExinspOclpoint了。
 */
public class ExinspOclpointDTO extends ExinspOclpoint{
    

    private String pipeLineName;//管道名称
    private String nagmCustomNumber;//附件测试桩自定义编号

    private String repairSuggestion_label;//评价维修建议：立即维修；计划维修；暂不维修；监控
    
    private String repairState_label;//维修状态中文
    
    private String exinspTaskName;//漏损点外检项目名称
    
    /**
     * 杂散电流干扰程度_交流干扰（强、中、弱）
     */
    private String acInterference_label;

    /**
     * 杂散电流干扰程度_直流干扰（强、中、弱）
     */
    private String dcInterference_label;

    private BigDecimal mileage2;
    private BigDecimal nagmMileage2;
    

    public BigDecimal getMileage2() {
        Long mileage = getMileage();
        if(mileage2 == null && mileage != null){
            mileage2 = new BigDecimal(mileage).movePointLeft(3);
        }
        return mileage2;
    }


    public BigDecimal getNagmMileage2() {
        Long mileage = getNagmMileage();
        if(nagmMileage2 == null && mileage != null){
            nagmMileage2 = new BigDecimal(mileage).movePointLeft(3);
        }
        return nagmMileage2;
    }


    public String getRepairState_label() {
        String str_temp = getRepairState();
        if(str_temp == null){
            return "";
        }
        if(repairState_label == null){
            repairState_label = RepairStateEnum.valueOf(str_temp).getLabel();
        }
        return repairState_label;
    }


    public String getPipeLineName() {
        return pipeLineName;
    }


    public String getRepairSuggestion_label() {
        String str_temp = getRepairSuggestion();
        if(str_temp == null){
            return "";
        }
        if(repairSuggestion_label == null){
            repairSuggestion_label = CodeUtil.getName(str_temp);
        }
        return repairSuggestion_label;
    }


    public String getAcInterference_label() {
        String str_temp = getAcInterference();
        if(str_temp == null){
            return "";
        }
        if(acInterference_label == null){
            acInterference_label = CurrentFerenceEnum.valueOf(str_temp).getLabel();
        }
    
        return acInterference_label;
    }


    public String getDcInterference_label() {
        String str_temp = getDcInterference();
        if(str_temp == null){
            return "";
        }
        if(dcInterference_label == null){
            dcInterference_label = CurrentFerenceEnum.valueOf(str_temp).getLabel();
        }
        return dcInterference_label;
    }


    public void setPipeLineName(String pipeLineName) {
        this.pipeLineName = pipeLineName;
    }


    public String getNagmCustomNumber() {
        return nagmCustomNumber;
    }


    public void setNagmCustomNumber(String nagmCustomNumber) {
        this.nagmCustomNumber = nagmCustomNumber;
    }


    public String getExinspTaskName() {
        return exinspTaskName;
    }


    public void setExinspTaskName(String exinspTaskName) {
        this.exinspTaskName = exinspTaskName;
    }


}
